<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>Board Game Software: Game.h Source File</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Board Game Software
   &#160;<span id="projectnumber">1.0</span>
   </div>
   <div id="projectbrief">A board game interface w/ 2 game implementations</div>
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.8.0 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Variables</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">Game.h</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="preprocessor">#ifndef GAME_H</span>
<a name="l00002"></a>00002 <span class="preprocessor"></span><span class="preprocessor">#define GAME_H</span>
<a name="l00003"></a>00003 <span class="preprocessor"></span><span class="preprocessor">#include &lt;iostream&gt;</span>
<a name="l00004"></a>00004 <span class="preprocessor">#include &lt;string&gt;</span>
<a name="l00005"></a>00005 <span class="preprocessor">#include &quot;Board.h&quot;</span>
<a name="l00006"></a>00006 <span class="preprocessor">#include &lt;vector&gt;</span>
<a name="l00007"></a>00007 <span class="preprocessor">#include &lt;sstream&gt;</span>
<a name="l00008"></a>00008 <span class="preprocessor">#include &lt;utility&gt;</span>
<a name="l00009"></a>00009 <span class="preprocessor">#include &lt;time.h&gt;</span>
<a name="l00010"></a>00010 <span class="preprocessor">#include &lt;cstdlib&gt;</span>
<a name="l00011"></a>00011 
<a name="l00012"></a><a class="code" href="class_game.html">00012</a> <span class="keyword">class </span><a class="code" href="class_game.html">Game</a>
<a name="l00013"></a>00013 {
<a name="l00014"></a>00014     <span class="keyword">public</span>:
<a name="l00015"></a>00015         <a class="code" href="class_game.html#ad59df6562a58a614fda24622d3715b65">Game</a>(); 
<a name="l00016"></a>00016         <span class="keyword">virtual</span> <a class="code" href="class_game.html#ae3d112ca6e0e55150d2fdbc704474530">~Game</a>(); 
<a name="l00017"></a>00017         <span class="keywordtype">int</span> <a class="code" href="class_game.html#a1d652f9f945163ddbdbea00b28916532">getPlayerTurn</a> () <span class="keyword">const</span>; 
<a name="l00018"></a>00018         <span class="keywordtype">void</span> <a class="code" href="class_game.html#ae8638ccdb0ef3bf39a6affa30aa1258f">startGame</a>(); 
<a name="l00019"></a>00019         <span class="keywordtype">void</span> <a class="code" href="class_game.html#ad7abf6b94faaeecdad981d3f8b6bfc7b">endGame</a>(<span class="keywordtype">int</span> winner); 
<a name="l00025"></a>00025         <span class="keywordtype">void</span> <a class="code" href="class_game.html#a5a74cd23d3e6aa33686c7daa78cb3d15">makeMove</a>(<a class="code" href="struct_point.html">Point</a> from, <a class="code" href="struct_point.html">Point</a> to);
<a name="l00031"></a>00031         <span class="keywordtype">void</span> <a class="code" href="class_game.html#ade49349011e3a6f7fb48f5c123697fcd">makeSilentMove</a>(<a class="code" href="struct_point.html">Point</a> from, <a class="code" href="struct_point.html">Point</a> to);
<a name="l00032"></a>00032         <span class="keywordtype">bool</span> <a class="code" href="class_game.html#a27fb911d996bc26ffba352c16ebc4110">undoMove</a>(); 
<a name="l00033"></a>00033         <span class="keywordtype">void</span> printBoard() <span class="keyword">const</span>; 
<a name="l00034"></a>00034         <span class="comment">// Virtual functions</span>
<a name="l00040"></a>00040 <span class="comment"></span>        <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_game.html#aa4e9f8d995d7429921e698c7af43f5c8">legalMoves</a>(std::vector&lt;Point&gt;&amp; p_pieces, std::vector&lt;MyPair&gt;&amp; collectPoints) = 0;
<a name="l00045"></a>00045         <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="class_game.html#a4894366f6988ccc716881cee0e58d776">terminalState</a>() = 0;
<a name="l00050"></a>00050         <span class="keyword">virtual</span> std::string <a class="code" href="class_game.html#a20693b7ae3eba68bd0f4bdf98a4f6efd">getName</a>() <span class="keyword">const</span> = 0;
<a name="l00051"></a>00051         <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_game.html#a6f77bf581e55b622a1e477b72955c240">go</a>() = 0; 
<a name="l00052"></a>00052         <span class="keywordtype">int</span> <a class="code" href="class_game.html#a9fb895bd0ce0684a2cf95d3d212487df">evaluate</a>(); 
<a name="l00053"></a>00053         <span class="keywordtype">int</span> <a class="code" href="class_game.html#a7a8fc4750d12f2dbb47c9256e9edfde1">MiniMax</a>(State s, <a class="code" href="struct_point.html">Point</a>&amp; from, <a class="code" href="struct_point.html">Point</a>&amp; to, <span class="keywordtype">int</span> depth); 
<a name="l00054"></a>00054         std::vector&lt;Point&gt; <a class="code" href="class_game.html#aab825aba93bcbe550cdfe7458a2be132">arrayOfPoints</a>(); 
<a name="l00055"></a>00055         <span class="comment">// Getters &amp; Setters</span>
<a name="l00056"></a>00056         <span class="keywordtype">int</span> <a class="code" href="class_game.html#a2d1ca8e45d32a752b7f6eecfd0629a62">getRound</a>() <span class="keyword">const</span>; 
<a name="l00057"></a>00057         <span class="keywordtype">void</span> <a class="code" href="class_game.html#a53c868caf158d92509f6db2cd7397362">incRound</a>(); 
<a name="l00058"></a>00058         std::string <a class="code" href="class_game.html#af6894aff3da555df76732aff9b8c6bfb">getLevel</a>() <span class="keyword">const</span>; 
<a name="l00059"></a>00059         <span class="keywordtype">void</span> <a class="code" href="class_game.html#a105ae15af4972344d07c426b558156f6">setLevel</a>(std::string l); 
<a name="l00060"></a>00060         <span class="keywordtype">bool</span> <a class="code" href="class_game.html#ac5a9475123e78fb8123230d6f182417a">isGameStarted</a>() <span class="keyword">const</span>; 
<a name="l00061"></a>00061     <span class="keyword">protected</span>:
<a name="l00062"></a>00062         <span class="keywordtype">bool</span> m_gameStarted;
<a name="l00063"></a><a class="code" href="class_game.html#af5a5d73d223ac6e520058a1719bfb55d">00063</a>         <span class="keywordtype">int</span> <a class="code" href="class_game.html#af5a5d73d223ac6e520058a1719bfb55d">m_round</a>; 
<a name="l00064"></a><a class="code" href="class_game.html#a908e5e24a5c44bd0b38dd8ff4ac56d4a">00064</a>         std::vector&lt;State&gt; <a class="code" href="class_game.html#a908e5e24a5c44bd0b38dd8ff4ac56d4a">m_allMoves</a>; 
<a name="l00065"></a><a class="code" href="class_game.html#a9b06e8378ea2c6dab974219ccc6007f7">00065</a>         <a class="code" href="class_board.html">Board</a>* <a class="code" href="class_game.html#a9b06e8378ea2c6dab974219ccc6007f7">m_board</a>; 
<a name="l00066"></a><a class="code" href="class_game.html#af4e49101c1b53d5537fbb3d9d5756220">00066</a>         std::string <a class="code" href="class_game.html#af4e49101c1b53d5537fbb3d9d5756220">m_level</a>; 
<a name="l00067"></a>00067 };
<a name="l00068"></a>00068 
<a name="l00069"></a>00069 <span class="preprocessor">#endif // GAME_H</span>
</pre></div></div><!-- contents -->


<hr class="footer"/><address class="footer"><small>
Generated on Sat May 12 2012 04:42:38 for Board Game Software by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.0
</small></address>

</body>
</html>
